/*
 *  Blazon: A user datagram protocol re-braodcasting daemon.
 *  log.h: Header file for log.c
 *
 *  Copyright 2012 Blazon development team
 *
 *  This program is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation, either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef INCLUDED_log_h
#define INCLUDED_log_h

#define LOG_BUFSIZE	512
#define DATETIME_SIZE	20

#define LOG_MAIN	1
#define LOG_ERR		1
#define LOG_WARN	2
#define LOG_INFO	3
#define LOG_DEBUG	4
#define LOG_STDOUT	5	/* This needs to be last */

extern bool logging_open(const char *, int);
extern bool logging_reopen(const char *, int);
extern void logging_close(void);
extern void log_main(const char *, ...);
extern void log_err(const char *, ...);
extern void log_warn(const char *, ...);
extern void log_info(const char *, ...);
extern void log_debug(const char *, ...);

#endif
